home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
17 Bit Software 5: The Fifth Dimension
/
17 Bit - The Fifth Dimension (1995)(17 Bit Software)[!].iso
/
files
/
3414a.dms
/
3414a.adf
/
3.0bUpdate
/
PostScript.LHA
/
PostScript.prolog
< prev
Wrap
Text File
|
1994-10-13
|
18KB
|
813 lines
%%BeginProlog
% $VER: PostScript.prolog 1.0b (29.9.94)
% fixed picstr problem in BeginRGBBitmap (7.10.94)
%Copyright 1994 Soft-Logik Publishing Corp.
/AsphaltDict dup 153 dict def load begin
%
% basic definitions
%
/bdef {bind def} bind def
/xdef {exch def} bdef
/ldef {load def} bdef
/dmatrix matrix def
/cmatrix matrix def
/omatrix matrix def
/deltax 0 def
/deltay 0 def
/slant 0 def
/twist 0 def
/xscl 0 def
/yscl 0 def
/bang 0 def
/eang 0 def
/tilescalex 0 def
/tilescaley 0 def
/bh 0 def
/bv 0 def
%
% drawing definitions
%
/sclm [0 0 0 0 0 0] def
/sr {
/twist xdef
/slant xdef
/deltay xdef
/deltax xdef
cmatrix setmatrix deltax deltay translate
sclm 0 twist cos put
sclm 1 twist sin put
sclm 2 slant sin neg put
sclm 3 slant cos put
sclm concat
/omatrix omatrix currentmatrix def
}bdef
/scl {
deltay sub exch
deltax sub exch
transform round .2 add exch round .2 add exch itransform
}bdef
%
% - patternpath -
%
/patternpath { %bdef
/mypatternfont findfont begin FontDict /ctm get setmatrix
currentdict setfont
FontDict begin
FontMatrix concat
width 0 dtransform
round width div exch round width div exch
0 height dtransform
round height div exch
round height div exch
0 0 transform round exch round exch
ptm astore setmatrix
pathbbox
height div ceiling height mul 4 1 roll
width div ceiling width mul 4 1 roll
height div floor height mul 4 1 roll
width div floor width mul 4 1 roll
2 index sub height div ceiling cvi exch
3 index sub width div ceiling cvi exch
4 2 roll moveto
FontMatrix ptm invertmatrix pop
{ %repeat
gsave
ptm concat
dup str length idiv {str show} repeat
dup str length mod str exch 0 exch getinterval show
grestore
0 height rmoveto
} repeat
pop
end end
}bdef
%
% - patternfill -
%
/patternfill { %bdef
gsave
1 setgray
fill
grestore
gsave
clip patternpath
grestore
newpath
}bdef
%
% - patterneofill -
%
/patterneofill { %bdef
gsave
1 setgray
eofill
grestore
gsave
eoclip patternpath
grestore
newpath
}bdef
%
% - patternstroke -
%
/patternstroke { %bdef
strokepath
gsave
1 setgray
eofill
grestore
gsave
clip patternpath
grestore
newpath
}bdef
%
% - N -
%
/N /newpath ldef
%
% x y M -
%
/M {scl moveto}bdef
%
% x y L -
%
/L {scl lineto}bdef
%
% cx1 cy1 cx2 cy2 px2 py2 C -
%
/C {scl 6 2 roll scl 6 2 roll scl 6 2 roll curveto} bdef
%
% cx cy rx ry ba ea slant twist A -
%
/A {
/twist xdef
/slant xdef
/eang xdef
/bang xdef
/yscl xdef
/xscl xdef
scl translate xscl yscl scale
sclm 0 twist cos put
sclm 1 twist sin put
sclm 2 slant sin neg put
sclm 3 slant cos put
sclm concat
0 0 1 bang eang arc omatrix setmatrix
}bdef
%
% cx cy rx ry ba ea slant twist AN -
%
/AN {
/twist xdef
/slant xdef
/eang xdef
/bang xdef
/yscl xdef
/xscl xdef
scl translate xscl yscl scale
sclm 0 twist cos put
sclm 1 twist sin put
sclm 2 slant sin neg put
sclm 3 slant cos put
sclm concat
0 0 1 bang eang arcn omatrix setmatrix
}bdef
%
% - CP -
%
/CP {closepath}bdef
%
% fill defines
%
/SG /setgray ldef
%
% /fillproc c m y k CMYK -
%
/CMYK {
setcmykcolor load exec
}def
%
% /fillproc sx sy l w angle /ramp [c1 m1 y1 k1][c2 m2 y2 k2] CMYKGRAD -
%
/CMYKGRAD {
/tc2 xdef
/tc1 xdef
/ramp exch ldef
/angle xdef
pop pop pop pop
/fillproc exch ldef
gsave cmatrix setmatrix flattenpath clip
pathbbox /ury xdef /urx xdef /lly xdef /llx xdef
angle 0 lt{/angle angle 360 add def}if
angle 180 gt{/angle angle 180 sub def tc1 tc2 /tc1 xdef /tc2 xdef}if
angle 90 gt{ /quad {ury exch sub} bdef tc1 tc2 /tc1 xdef /tc2 xdef}{ /quad {lly add} bdef}ifelse
/l urx llx sub def
/w ury lly sub def
/v angle dup 90 gt{90 sub neg 90 add}if dup sin l mul exch cos w mul add 2 mul def
/d angle dup 90 gt{90 sub neg 90 add}if dup sin w mul exch cos l mul add def
/steps d 72 div currentscreen pop pop mul cvi 1 add dup 256 gt{pop 256}if def
/dd d steps div def
0 1 steps
{
steps div dup /frac xdef ramp /rfrac xdef
tc2 0 get tc1 0 get sub rfrac mul tc1 0 get add
tc2 1 get tc1 1 get sub rfrac mul tc1 1 get add
tc2 2 get tc1 2 get sub rfrac mul tc1 2 get add
tc2 3 get tc1 3 get sub rfrac mul tc1 3 get add setcmykcolor
newpath gsave
l frac mul llx add
w frac mul quad translate angle rotate
dd 2 div neg v 2 div neg moveto
0 v rlineto dd 0 rlineto 0 v neg rlineto closepath
fillproc grestore
} for
grestore
}def
%
% this is the orginal
%
%/CMYKGRAD {
% /tc2 xdef
% /tc1 xdef
% /ramp exch ldef
% /angle xdef
% /w xdef /l xdef scl /sy xdef /sx xdef
% /fillproc exch ldef
%
% /steps 256 def
% /dx l steps div def
%
% gsave clip
%
% sx sy translate angle rotate
%
% 0 1 steps
% {
% steps div dup /frac xdef ramp /rfrac xdef
% tc2 0 get tc1 0 get sub rfrac mul tc1 0 get add
% tc2 1 get tc1 1 get sub rfrac mul tc1 1 get add
% tc2 2 get tc1 2 get sub rfrac mul tc1 2 get add
% tc2 3 get tc1 3 get sub rfrac mul tc1 3 get add setcmykcolor
% newpath l frac mul w -2 div moveto 0 w rlineto dx 0 rlineto 0 w neg rlineto closepath fillproc
% } for
%
% grestore
%
%}def
%
% /fillproc xc yc radius /ramp [c1 m1 y1 k1][c2 m2 y2 k2] CMYKRADIAL -
%
/CMYKRADIAL {
/tc2 xdef
/tc1 xdef
/ramp exch ldef
/radius xdef
scl /yc xdef /xc xdef
/fillproc exch ldef
/steps 256 def
gsave clip
steps -1 0
{
steps div dup /frac xdef ramp /rfrac xdef
tc2 0 get tc1 0 get sub rfrac mul tc1 0 get add
tc2 1 get tc1 1 get sub rfrac mul tc1 1 get add
tc2 2 get tc1 2 get sub rfrac mul tc1 2 get add
tc2 3 get tc1 3 get sub rfrac mul tc1 3 get add setcmykcolor
newpath xc yc radius frac mul 0 360 arc fillproc
} for
grestore
}def
%
% /fillproc inset /ramp [c1 m1 y1 k1][c2 m2 y2 k2] CMYKSHAPE -
%
/CMYKSHAPE {
/tc2 xdef
/tc1 xdef
/ramp exch ldef
/xc xdef
/fillproc exch ldef
/steps 30 def
currentflat mark currentflat
{
{
dup setflat mark clip
tc1 0 get tc1 1 get tc1 2 get tc1 3 get setcmykcolor
currentflat mark currentflat
{
dup setflat mark
{fillproc} gsave stopped grestore {cleartomark 1.3 mul dup 100 gt {cleartomark setflat stop}if}{cleartomark exit} ifelse
}loop
cleartomark setflat
steps -1 0
{
steps div dup /frac xdef ramp /rfrac xdef
tc1 0 get tc2 0 get sub rfrac mul tc2 0 get add
tc1 1 get tc2 1 get sub rfrac mul tc2 1 get add
tc1 2 get tc2 2 get sub rfrac mul tc2 2 get add
tc1 3 get tc2 3 get sub rfrac mul tc2 3 get add setcmykcolor
[]0 setdash xc 2 mul frac mul setlinewidth
currentflat mark currentflat
{
dup setflat mark
{ST} gsave stopped grestore {cleartomark 1.3 mul dup 100 gt {cleartomark setflat stop}if}{cleartomark exit} ifelse
}loop
cleartomark setflat
} for
}
% gsave stopped grestore {cleartomark 1.3 mul dup 100 gt {cleartomark setflat stop}if}{cleartomark exit} ifelse
gsave stopped grestore {cleartomark 1.3 mul dup 100 gt {exit}if}{cleartomark exit} ifelse
}loop
cleartomark setflat
}def
%
% - S -
%
/S {
/MF /eofill ldef
/MS /fill ldef
/ST /stroke ldef
} bdef
%
% <pattern> P -
%
/P {
/pattern xdef
/mypatternfont findfont begin
FontDict begin
true
0 1 patterncount 1 sub {
dup patterns exch get pattern eq
{0 1 str length 1 sub{str exch 2 index put}for pop pop false exit}
if
pop
}for
{
patterns patterncount pattern put
0 1 str length 1 sub {str exch patterncount put}for
/patterncount patterncount 1 add def
}if
end
end
/MF /patterneofill ldef
/MS /patternfill ldef
/ST /patternstroke ldef
} bdef
%
% join miterlimit cap [dashpattern] width ST -
%
/st {
setlinewidth 0 setdash setlinecap
2 div sin 1 exch div setmiterlimit
setlinejoin strokepath
}bdef
%
% endfunc scale angle x y LNE -
%
/LNE {
scl translate rotate dup scale
load exec
omatrix setmatrix
}bdef
%
% screen spot functions
%
/SSNewDot {180 mul cos exch 180 mul cos add 2 div}bdef
/SSDot {dup mul exch dup mul add 1.0 exch sub}bdef
/SSRing {dup mul exch dup mul add 1.0 exch sub abs 1.0 exch sub}bdef
/SSDonut {dup mul exch dup mul add sqrt .5 sub abs 1.0 exch sub}bdef
/SSLine {exch pop abs}bdef
/SSTriangle {2 exch sub exch abs 2 mul sub 3 div}bdef
/SSPropeller {/y xdef /x xdef y x .001 add atan cvi 72 mod 72 sub abs 72 div y y mul x x mul add 1 exch sub add 2 div}bdef
%
% fountain blend functions
%
/FBLinear {}bdef
/FBInvLinear {1 exch sub}bdef
/FBLog {9 mul 1 add log}bdef
/FBInvLog {9 mul 1 add log 1 exch sub}bdef
/FBSin {180 mul sin}bdef
/FBInvSin {180 mul sin 1 exch sub}bdef
/FBSaw {2 mul dup 1 gt {2 exch sub}if}bdef
/FBInvSaw {2 mul dup 1 gt {2 exch sub}if 1 exch sub}bdef
%
% line end functions
%
/LERound {0 0 moveto 0 0 .5 -90 90 arc closepath}bdef
/LEArrow {0 0 moveto 0 2 lineto 6 0 lineto 0 -2 lineto closepath}bdef
/LEArrow1 {0 0 moveto 0 2 lineto 6 0 lineto 0 -2 lineto closepath}bdef
/LEArrow2 {0 0 moveto -2 2 lineto 6 0 lineto -2 -2 lineto closepath}bdef
/LEArrow3 {6 0 moveto -3 0 2.31 300 60 arc closepath}bdef
/LEArrow4 {-1 0 moveto -4 2 .5 240 60 arcn 0 0 .5 60 300 arcn -4 -2 .5 300 120 arcn closepath}bdef
/LESpike1 {0 .5 moveto .5 2 lineto 1 .5 lineto 6 0 lineto 1 -.5 lineto .5 -2 lineto 0 -.5 lineto closepath}bdef
/LESpike2 {0 .5 moveto 2 2 lineto 6 0 lineto 2 -2 lineto 0 -.5 lineto closepath}bdef
/LEFeather1 {-2 0 moveto 0 2 lineto 6 2 lineto 4 0 lineto 6 -2 lineto 0 -2 lineto closepath}bdef
/LEFeather2 {0 -2 moveto 0 0 2 270 90 arcn 6 0 2 90 270 arc closepath}bdef
/LEBox {-2 0 moveto -2 2 lineto 2 2 lineto 2 -2 lineto -2 -2 lineto closepath}bdef
/LEDiamond {-2 0 moveto 0 2 lineto 2 0 lineto 0 -2 lineto closepath}bdef
/LEBall {0 0 moveto 0 0 2 360 0 arcn closepath}bdef
/LEEllipse {2 1 scale 0 0 moveto 0 0 2 360 0 arcn closepath}bdef
%
% freq angle spot SS -
%
/ss {
load setscreen
}bdef
/installcolor {
dup type /stringtype eq {pop dangle}if exch dup type /stringtype eq {pop dfreq}if exch /dspot load setscreen
/sepmode xdef
sepmode 1 eq {
/setcmykcolor{1 sub 4 1 roll 3{3 index add neg dup 0 lt{pop 0}if 3 1 roll}repeat setrgbcolor pop}bdef
/setgray /SG load def
}if
sepmode 2 eq {
systemdict /setcmykcolor known not {/setcmykcolor {1 sub 4 1 roll 3 {3 index add neg dup 0 lt{pop 0}if 3 1 roll} repeat setrgbcolor pop}bdef}if
/setgray /SG load def
}if
sepmode 3 eq {
/sepcolor xdef
sepcolor 0 get 0 ne {/setcmykcolor {pop pop pop 1 exch sub SG}bdef /setgray {pop 1 SG}bdef } if
sepcolor 1 get 0 ne {/setcmykcolor {pop pop 1 exch sub SG pop}bdef /setgray {pop 1 SG}bdef } if
sepcolor 2 get 0 ne {/setcmykcolor {pop 1 exch sub SG pop pop}bdef /setgray {pop 1 SG}bdef } if
sepcolor 3 get 0 ne {/setcmykcolor {1 exch sub SG pop pop pop}bdef /setgray /SG load def } if
} if
sepmode 4 eq {
/sepcolor xdef
/setcmykcolor {
sepcolor 3 get eq exch
sepcolor 2 get eq and exch
sepcolor 1 get eq and exch
sepcolor 0 get eq and {0 SG}{1 SG}ifelse}bdef
sepcolor 3 get 1 eq sepcolor 2 get 0 eq and sepcolor 1 get 0 eq and sepcolor 0 get 0 eq and {/setgray /SG load def}{/setgray {pop 1 SG} bdef} ifelse
} if
currentscreen /cspot xdef /cangle xdef /cfreq xdef
}bdef
%
% #copies BEGINDOCUMENT -
%
/BeginDocument {
/#copies xdef
7 dict begin
/FontDict 12 dict def
FontDict begin
/key /mypatternfont def
/patterns 256 array def
/patterncount 0 def
/char 0 def
/mtx [300 72 div 0 0 300 72 div 0 0] matrix invertmatrix def
/height 30 def
/width 30 def
/ctm matrix currentmatrix def
/ptm matrix identmatrix def
/str 32 string def
end
/FontBBox [0 0 FontDict /width get FontDict /height get] def
/FontMatrix FontDict /mtx get def
/Encoding 256 array 0 1 255 {1 index exch dup 3 string cvs cvn put} for def
/FontType 3 def
/BuildChar { %def
exch begin
FontDict begin
/char xdef
width 0 0 0 width height setcachedevice
width height scale 8 8 true [8 0 0 -8 0 8] {patterns char get} imagemask
end end
} def
FontDict /key get currentdict definefont pop
end
/dmatrix dmatrix currentmatrix def
currentscreen /dspot xdef /dangle xdef /dfreq xdef
}bdef
%
% /fontname xscale yscale F -
%
/f {
/yscale xdef /xscale xdef
findfont [xscale 0 0 yscale 0 0] makefont setfont
}bdef
%
% (string) s1 -
%
/s1 {show}bdef
%
% (string) kernamt s2 -
%
/s2 {exch 0 exch ashow}bdef
%
% (string) skernamt s3 -
%
/s3 {exch 0 exch 32 exch widthshow}bdef
%
% (string) skernamt kernamt s4 -
%
/s4 {0 exch 32 exch 0 6 -1 roll awidthshow}bdef
%
% - ENDOCUMENT -
%
/EndDocument {
}bdef
%
% [sepcolor] sepmode freq/(DEFAULT) angle/(DEFAULT) tilew tileh landscape scaleh scalex paperw paperh BEGINTILE -
%
/BeginTile {
2 div exch 2 div exch translate
/tilescaley xdef /tilescalex xdef tilescalex tilescaley scale
{-90 rotate}if
-2 div exch -2 div exch translate
installcolor
/cmatrix cmatrix currentmatrix def
% default to solid fills
S
}bdef
%
% angle cx cy cropmark -
%
/cropmark {
gsave translate 1 tilescalex div 1 tilescaley div scale rotate
.3 setlinewidth newpath
bh 5 add 0 moveto 20 0 rlineto
0 bv 5 add moveto 0 20 rlineto
stroke grestore
} bdef
%
% dx dy cx cy regmark -
%
/regmark {
gsave translate 1 tilescalex div 1 tilescaley div scale translate
.3 setlinewidth newpath
10 0 moveto 0 0 10 0 360 arc
1 SG fill
8 0 moveto 0 0 8 0 360 arc
-10 0 moveto 10 0 lineto 0 -10 moveto 0 10 lineto
0 SG stroke
4 0 moveto 0 0 4 0 360 arc
fill
-4 0 moveto 4 0 lineto 0 -4 moveto 0 4 lineto
1 SG stroke
grestore
} bdef
%
% dx dy cx cy slurgauge -
%
/slurgauge {
gsave translate 1 tilescalex div 1 tilescaley div scale translate
.3 setlinewidth newpath
0 0 10 0 360 arc
1 SG fill
0 0 10 0 360 arc
0 SG stroke
36 { 1 0 moveto 0 0 10 -2.5 2.5 arc fill 10 rotate} repeat
grestore
} bdef
/boxit {newpath moveto 14 0 rlineto 0 -14 rlineto -14 0 rlineto closepath} def
%
% angle dx dy cx cy colorstrip -
%
/colorstrip {
gsave translate 1 tilescalex div 1 tilescaley div scale translate rotate
/Courier findfont 6 scalefont setfont
sepmode 1 eq {
0 8 translate
0 1 9 {dup 15 mul 0 boxit 10 div SG fill} for
}if
sepmode 2 eq sepmode 3 eq or {
gsave 320 15 translate
0 0 boxit .5 .41 .41 0 setcmykcolor fill
15 0 boxit 0 0 0 .5 setcmykcolor fill
30 0 boxit 1 1 0 0 setcmykcolor fill
45 0 boxit 1 0 1 0 setcmykcolor fill
60 0 boxit 0 1 1 0 setcmykcolor fill
75 0 boxit 1 1 1 0 setcmykcolor fill
1 SG
33 -6 moveto (CM) show
48 -6 moveto (CY) show
63 -6 moveto (MY) show
77 -6 moveto (CMY) show
grestore
0 0 0 1 setcmykcolor -6 9 moveto (K) show
0 1 9 {dup 15 mul 15 boxit 10 div 0 0 0 4 -1 roll setcmykcolor fill} for
1 0 0 0 setcmykcolor -6 -6 moveto (C) show
0 1 9 {dup 15 mul 0 boxit 10 div 0 0 0 setcmykcolor fill} for
0 1 0 0 setcmykcolor 154 9 moveto (M) show
0 1 9 {dup 15 mul 160 add 15 boxit 10 div 0 exch 0 0 setcmykcolor fill} for
0 0 1 0 setcmykcolor 154 -6 moveto (Y) show
0 1 9 {dup 15 mul 160 add 0 boxit 10 div 0 0 3 -1 roll 0 setcmykcolor fill} for
}if
sepmode 4 eq {
320 0 translate
0 1 9 {dup 15 mul 0 boxit 10 div SG fill} for
}if
grestore
} def
%
% title1 title2 tilew tileh PRINTERSMARKS -
%
/PrintersMarks {
/tileh xdef
/tilew xdef
/title2 xdef
/title1 xdef
gsave 0 SG [] 0 setdash 0 setlinejoin 0 setlinecap
180 0 0 cropmark
270 tilew 0 cropmark
0 tilew tileh cropmark
90 0 tileh cropmark
0 15 bv add tilew 2 div tileh regmark
0 -15 bv sub tilew 2 div 0 regmark
-15 bh sub -15 bv sub 0 0 slurgauge
15 bh add 15 bv add tilew tileh slurgauge
gsave 1 tilescalex div 1 tilescaley div scale -15 bh sub 8 translate 90 rotate
/Courier findfont 8 scalefont setfont
0 0 moveto title1 show
0 -8 moveto title2 show ( ) show
currentscreen pop exch 20 string cvs show ( lpi ) show
20 string cvs show (\312 ) show
tilescalex 100 mul 20 string cvs show (%) show
tilescaley tilescalex ne {(,) show tilescaley 100 mul 20 string cvs show (%) show}if
grestore
90 bh 15 add 15 tilew 0 colorstrip
grestore
}bdef
%
% [sepcolor] sepmode freq/(DEFAULT) angle/(DEFAULT) title left top right bottom THUMBNAILMARKS -
%
/ThumbnailMarks {
/tiley2 xdef
/tilex2 xdef
/tiley1 xdef
/tilex1 xdef
/title1 xdef
cmatrix setmatrix
.5 SG 6 setlinewidth
newpath
tilex1 3 add tiley2 3 sub moveto
tilex2 3 add tiley2 3 sub lineto
tilex2 3 add tiley1 3 sub lineto stroke
0 SG [] 0 setdash .3 setlinewidth 0 setlinejoin 0 setlinecap
newpath tilex1 tiley1 moveto tilex2 tiley1 lineto tilex2 tiley2 lineto tilex1 tiley2 lineto closepath stroke
gsave tilex1 tilex2 add 2 div tiley2 translate 1 tilescalex div 1 tilescaley div scale -2 -6 bv sub translate
/Courier findfont 6 scalefont setfont
0 0 moveto title1 show
grestore
installcolor
}bdef
%
% - ENDTILE -
%
/EndTile {
}bdef
%
% - BEGINCLIP -
%
/BeginClip {/PGSClipSave save def clip}bdef
%
% - ENDCLIP -
%
/EndClip {PGSClipSave restore}bdef
%
% xscale yscale xoffset yoffset pixelw pixelh bitsperpixel BEGINBITMAP -
%
/BeginBitmap {
/bpp xdef /h xdef /w xdef
scl translate scale save /picstr 8 bpp idiv dup w add 1 sub exch idiv string def
w h bpp [w 0 0 h neg 0 h] {currentfile picstr readhexstring pop}bind image
}bdef
%
% xscale yscale xoffset yoffset pixelw pixelh bitsperpixel BEGINRGBBITMAP -
%
/BeginRGBBitmap {
/bpp xdef /h xdef /w xdef
scl translate scale save /picstr 8 bpp idiv dup w 3 mul add 1 sub exch idiv string def
w h bpp [w 0 0 h neg 0 h] {currentfile picstr readhexstring pop}bind false 3 colorimage
}bdef
%
% - ENDBITMAP -
%
/EndBitmap {restore omatrix setmatrix}bdef
%
% xscalex yscale xoffset yoffset BEGINEPS -
%
/BeginEPS {
scl translate scale translate
/PGSEPSSave save def /showpage {} bdef
newpath [] 0 setdash 1 setlinewidth 0 setgray
}bdef
%
% - ENDEPS -
%
/EndEPS {PGSEPSSave restore}bdef
end
%%EndProlog